package gui;

import java.awt.BorderLayout;

import javax.swing.JDialog;
import javax.swing.JTabbedPane;

import languages.Language;

public class DialogInsertArc extends JDialog {
	
	private TabInsertArcMiliseconds tiAM;
	private TabInsertArcDegrees tiAD;
	
	private static DialogInsertArc obj = null;
	
	public DialogInsertArc(Window parent, Language lang){
		
		super(parent, lang.dialogInsertArcTitle(), true);

		obj = this;

		this.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);
		this.getContentPane().setLayout(new BorderLayout());
		
		//tabbed pane
		JTabbedPane tabbedPane = new JTabbedPane();
		
		tiAM = new TabInsertArcMiliseconds(lang, parent);
		tiAD = new TabInsertArcDegrees(lang, parent);
		
		tabbedPane.addTab(lang.tiPMTitle(), tiAM);
		tabbedPane.addTab(lang.tiPDTitle(), tiAD);
		
		this.getContentPane().add(BorderLayout.CENTER, tabbedPane);
		
		this.pack();
		
		this.setVisible(true);
	}
	
}
